package com.kedeng.yangmuyi.model;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

@Entity
@Table(name = "TPROFILE")
public class ProfileDO extends BaseDO {

    private static final long serialVersionUID = -1021646508112433435L;



    public ProfileDO() {
    }



    public ProfileDO(String userName, String passwordWithMD5, String email, String gender, String qq,
            String mobilePhone, String phone, String address, String comment, Date birthday, RoleGroupDO role) {
        super();
        this.userName = userName;
        this.passwordWithMD5 = passwordWithMD5;
        this.email = email;
        this.gender = gender;
        this.qq = qq;
        this.mobilePhone = mobilePhone;
        this.phone = phone;
        this.address = address;
        this.comment = comment;
        this.birthday = birthday;
        this.role = role;
    }

    @Column(nullable = false)
    private String      userName;
    @Column
    private String      passwordWithMD5;
    @Column
    private String      email;
    @Column
    private String      gender;
    @Column
    private String      qq;
    @Column
    private String      mobilePhone;
    @Column
    private String      phone;
    @Column
    private String      address;
    @Column(length = 10000)
    private String      comment;
    // timestamp is hibernate type to mapping the date type in database.
    @Temporal(TemporalType.TIMESTAMP)
    @Column(name = "BIRTHDAY")
    private Date        birthday;
    @Column
    private RoleGroupDO role;



    /**
     * @return the userName
     */
    public String getUserName() {
        return userName;
    }



    /**
     * @param userName
     *            the userName to set
     */
    public void setUserName(String userName) {
        this.userName = userName;
    }



    /**
     * @return the passwordWithMD5
     */
    public String getPasswordWithMD5() {
        return passwordWithMD5;
    }



    /**
     * @param passwordWithMD5
     *            the passwordWithMD5 to set
     */
    public void setPasswordWithMD5(String passwordWithMD5) {
        this.passwordWithMD5 = passwordWithMD5;
    }



    /**
     * @return the email
     */
    public String getEmail() {
        return email;
    }



    /**
     * @param email
     *            the email to set
     */
    public void setEmail(String email) {
        this.email = email;
    }



    /**
     * @return the gender
     */
    public String getGender() {
        return gender;
    }



    /**
     * @param gender
     *            the gender to set
     */
    public void setGender(String gender) {
        this.gender = gender;
    }



    /**
     * @return the qq
     */
    public String getQq() {
        return qq;
    }



    /**
     * @param qq
     *            the qq to set
     */
    public void setQq(String qq) {
        this.qq = qq;
    }



    /**
     * @return the mobilePhone
     */
    public String getMobilePhone() {
        return mobilePhone;
    }



    /**
     * @param mobilePhone
     *            the mobilePhone to set
     */
    public void setMobilePhone(String mobilePhone) {
        this.mobilePhone = mobilePhone;
    }



    /**
     * @return the phone
     */
    public String getPhone() {
        return phone;
    }



    /**
     * @param phone
     *            the phone to set
     */
    public void setPhone(String phone) {
        this.phone = phone;
    }



    /**
     * @return the address
     */
    public String getAddress() {
        return address;
    }



    /**
     * @param address
     *            the address to set
     */
    public void setAddress(String address) {
        this.address = address;
    }



    /**
     * @return the comment
     */
    public String getComment() {
        return comment;
    }



    /**
     * @param comment
     *            the comment to set
     */
    public void setComment(String comment) {
        this.comment = comment;
    }



    /**
     * @return the birthday
     */
    public Date getBirthday() {
        return birthday;
    }



    /**
     * @param birthday
     *            the birthday to set
     */
    public void setBirthday(Date birthday) {
        this.birthday = birthday;
    }



    /**
     * @return the role
     */
    public RoleGroupDO getRole() {
        return role;
    }



    /**
     * @param role
     *            the role to set
     */
    public void setRole(RoleGroupDO role) {
        this.role = role;
    }

}
